home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Network PC
/
Network PC.iso
/
windows 95 utilities
/
programming tools
/
freeman installer
/
userwnd.h_
/
userwnd
Wrap
Text File
|
1995-09-17
|
847b
|
60 lines
#define __USERWND_H
#ifndef __AWNDOBJ_H
#include "awndobj.h"
#endif
#ifndef __WNDIDATA_H
#include "wndidata.h"
#endif
class usercls
{
public:
usercls();
char *cname;
char *mname;
DWORD style;
HICON icon;
HBRUSH bkbrush;
HCURSOR cursor;
int reg();
};
class userwnd:public abswndobj
{
public:
userwnd();
~userwnd();
HWND wnd;
virtual LRESULT onmsg(UINT msg, WPARAM wp, LPARAM lp) = 0;
HWND getwnd()
{
return wnd;
}
void del()
{
if (wnd != 0)
{
DestroyWindow(wnd); /* wnd will be set to 0 in WM_DESTROY */
}
}
int create(usercls &c, wndinitdata &d)
{
d.p = this;
return (wnd = d.create(c.cname)) != 0;
}
void detach();
void attach(HWND wnd);
};